package xyz.zdsoft.course_manage_module.service;
import xyz.zdsoft.common.utils.Result;

import java.text.ParseException;
import java.util.HashMap;
import java.util.List;

public interface AdminInsertCourseService {
    //查询该课程是否存在
    Integer SelHaveCourse(String courseName);
    //如果课程不存在就新增课程
    void InsertCourse(String courseName);
    //获取课程id
    Integer SelCourseId(String courseName);
    //通过教室查询当日上课日期
    HashMap<String,Object> SelDateByClassRoom(String classRome);
    //查询实训老师是否是在业状态
    String SelTrainTeacher(Long teacherId);
    //查询实训老师是否存在
    Integer SelHaveTeacher(Long teacherId);
    //新增课程安排
    Integer InsertCourseOn(HashMap<String,Object> map);
    //查询新增的课程安排id
    Integer SelCourseOnIdBy(HashMap<String,Object> map);
    //新增课程安排与实训老师的对应关系
    void InsertCourseAndTrainTeacher(Integer courseOnId,Long trainTeacherId);

    //判断时间是否过期
    Integer updateTime(String projectDate,String signInTime)throws ParseException;
    // 判断时间是否冲突
    Integer judgeDateTime(List<HashMap<String,Object>> dateMaps, String classRome, String projectDate, String signInTime,String signOutTime) throws ParseException;
    //判断实训老师是否不存在或者停业
    Integer haveTeacher(Long[] trainTeachers);
    //总体逻辑判断
    Result judgeInsertCourse(String projectDate, String courseName,
                                    Long dutyTeacherId, Long[] trainTeachers,
                                    String signInTime, String signOutTime,
                                    String classRome, String remark) throws ParseException;
}
